package com.nut.service;

import org.apache.dubbo.config.annotation.Reference;
import org.springframework.stereotype.Service;

/**
 * @ author : HyoJoo-W
 * @ createDate : 2021-04-29 16:48
 * @ Description : 用户接口
 */

@Service
public class UserService
{
    //去注册中心拿到服务
    @Reference
    TicketService ticketService;

    public void buyTicket()
    {
        String ticket = ticketService.getTicket();
        System.out.println("在注册中心拿到的票为：" + ticket);
    }
}
